home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / scope / 201-220 / scopedisk217 / icontrol / icontrol.doc < prev    next >
Encoding:
Text File  |  1995-03-20  |  11.4 KB  |  288 lines

  1.                                ICONtrol
  2.  
  3.                               Version 1.0
  4.  
  5.                   © Copyright 1991, Stefan Winterstein
  6.  
  7.  
  8.  
  9.  
  10.                                 Overview
  11.                                 ========
  12.  
  13.     ICONtrol  is  an easy-to-use CLI-command that gives you control over
  14. Workbench  icons.  It's main purpose is to update the look of your icons
  15. for OS 2.0; this can be done by swapping the colors in an icon or giving
  16. new  images  to  them.   Moreover,  it  can  be  used to clear an icon's
  17. absolute  position in a drawer or on Workbench.  So it is also a helpful
  18. tool if you are not yet using OS 2.0.
  19.     ICONtrol  does   NOT  require  OS 2.0,  features  full  support  for
  20. AmigaDOS-wildcards,    can    recursively   enter   subdirectories,   is
  21. Enforcer-tested and may be made resident.
  22.  
  23.  
  24.                              A Quick Start
  25.                              =============
  26.  
  27.     ICONtrol  takes,  in that order, a path, a keyword and some optional
  28. parameters as arguments.  Here is a short description:
  29.  
  30. Path
  31.     may  be  any  file,  icon  or  directory;  if omitted, all icons are
  32. processed.  Amiga-DOS wildcards ARE supported.
  33.  
  34. WARNING:  Due  to  a  bug  in RAM-handler,  it is not recommended to use
  35.           ICONtrol on "RAM:"; see "Known Bugs" for details.
  36.  
  37. Keywords are:
  38.     RECOLOR             Switch between icon coloring
  39.                         for old and new Workbench.
  40.     GETIMAGE <from>     Give a new image to an icon. The name of the
  41.                         source icon follows the keyword directly.
  42.     FREEPOS             Let Workbench freely place the icon.
  43.  
  44.     ALL                 will recursively enter all sub-directories.
  45.  
  46. Types
  47.     are  "FILES",  "DIRS"  and  "DISKS".   If  one  or  more  of them is
  48. specified, only icons of these types will be changed.
  49.  
  50.     To see some examples simply skip the next section, which gives you a
  51. more detailed description of the program.
  52.  
  53.  
  54.                           How To Use ICONtrol
  55.                           ===================
  56.  
  57.     Important  note  for  1.2/1.3  users:  If you change an icon that is
  58. currently  visible  on  the  workbench,  it  will  not  automatically be
  59. changed  on  the  screen.  First close the window that contains the icon
  60. and open it again.
  61.  
  62. ICONtrol is invoked from the CLI; its syntax is as follows:
  63.  
  64.             ICONtrol [<path>] <keyword> [ALL] [<type>...]
  65.  
  66.     Parameters  in  []  may be omitted; so the only argument that really
  67. must  be  present is the keyword that determines what ICONtrol should do
  68. to the icons.  An explanation of the various components follows.
  69.  
  70. Path
  71. ----
  72.     ICONtrol  accepts  any  valid AmigaDOS(tm) path specification, which
  73. may  describe  a  directory, a single icon or a file pattern.  It is not
  74. necessary  to supply the ".info"-suffix.  The icon of a disk is the file
  75. "disk.info"  in  the  root  directory of that disk.
  76.  
  77.     Wildcards  are  fully  supported but are allowed for filenames only,
  78. not   for   directories.    So   "SYS:System/a#?"   is   valid,  whereas
  79. "SYS:S#?/a#?" is not.  Note that '*' is not a valid AmigaDOS wildcard.
  80.  
  81.     If  no  path  argument  is  given,  ICONtrol  works  in  the current
  82. directory  and  uses the universal wildcard "#?", matching all the icons
  83. it  can  find.  You can, however, specify the types of icons you wish to
  84. change,  see  section  on  "Types".
  85.  
  86.     Please  note  an  important convention:  if the pathname describes a
  87. directory, ICONtrol will interpret it as the icon of that directory, NOT
  88. its  contents.   Thus,  if  you  specify  "SYS:System",  the drawer icon
  89. "SYS:System.info" will be accessed, not the icons inside it.  This is to
  90. prevent  you  from  mistakenly changing the wrong icons.  If you want to
  91. change  the  contents  of  a  directory,  simply  append  a  '/'  as  in
  92. "SYS:System/".
  93.  
  94.  
  95. Keywords
  96. --------
  97.     ICONtrol's  operation controlled via keywords.  One of the following
  98. must be specified:
  99.  
  100. RECOLOR
  101.     This  switches  between  icon coloring for the old (pre 2.0) and new
  102. Workbench.   With  OS 2.0,  the  default  colors  for the Workbench were
  103. changed,  so  old  icons look rather strange on the new Workbench:  What
  104. used  to  be light is now dark and vice versa.  If you simply change two
  105. colors  (1  and 2), the icon will look normal again.  Of course, you can
  106. undo the change by recoloring the icon again, thus switching between the
  107. old and the new coloring.
  108.  
  109. GETIMAGE
  110.     This  gives a new image to an icon.  The pathname of the source icon
  111. must  follow  right after this keyword (again, the ".info"-suffix is not
  112. necessary).   Any  matching  icon  will  then  get the same image as the
  113. source  icon;  its type, drawer size, tooltypes and other parameters are
  114. not changed.  It is therefore possible to make a file look like a drawer
  115. or a drawer look like a disk.
  116.     In order to prevent you from accidently making all icons look alike,
  117. ICONtrol  checks  the  type  of  the  source  icon and, by default, only
  118. changes  icons of the same type.  If, for example, you use a drawer icon
  119. as  source, only icons belonging to directories will get this new image,
  120. whereas  file  icons  will  not.   To  override this precaution, you can
  121. explicitly specify which icon types to change; see section on "Types".
  122.  
  123. FREEPOS
  124.     This lets Workbench freely place an icon.  After freeing it, an icon
  125. has  no fixed position in a drawer (or on the screen).  It appears where
  126. Workbench  thinks  it  fits  best.   So if you do this to all icons in a
  127. drawer,  its  contents will always be displayed in a (more or less) neat
  128. arrangement.   Note  that  this does not affect the position and size of
  129. the window that a drawer opens, but only the position of the drawer icon
  130. itself.
  131.  
  132. HELP (or ?)
  133.     As  you  might  probably  have expected, this gives you a summary of
  134. this document.
  135.  
  136.  
  137. ALL
  138. ---
  139.     This   makes   ICONtrol  recursively  enter  all  subdirectories  it
  140. encounters  .   So if you specify "SYS:" as a pathname and use the "ALL"
  141. option,  all  directories  and  subdirectories of your boot disk will be
  142. searched for matching icons.
  143.  
  144.  
  145. Types
  146. -----
  147.     To  process  only  certain types of icons, say all drawer icons, you
  148. can specify one or more of the types "FILES", "DIRS" or "DISKS".  So the
  149. keyword  "RECOLOR"  along with type "DIRS" will change colors for drawer
  150. icons  only.   "FILES"  matches  project  and  tool icons, "DIRS" is for
  151. drawer icons, and "DISKS" will select disk (and kickstart) icons.
  152.     If  no type is specified, all icons regardless of their type will be
  153. processed.   (An  exception is "GETIMAGE", which by default only affects
  154. icons of the same type as the source icon; see there.)
  155.  
  156.  
  157.                                 Examples
  158.                                 ========
  159.  
  160. Changing single icons
  161. ---------------------
  162.     If  you  simply  want  to  change  colors for a single icon, say for
  163. "NoFastMem" in the "System" drawer, use
  164.  
  165.                  ICONtrol SYS:system/nofastmem recolor
  166.  
  167. This works for drawers, too:
  168.  
  169.                       ICONtrol SYS:system recolor
  170.  
  171. will  recolor  the  drawer  icon  of the "System" directory (but not the
  172. icons within!).
  173.  
  174.  
  175. Changing icons within drawers
  176. -----------------------------
  177.     To  clean  up  the  position  of  all icons within a drawer (say the
  178. "System" drawer), use the following:
  179.  
  180.                       ICONtrol SYS:system/ freepos
  181.  
  182.     If  you wanted to do this for all icons in a directory and below it,
  183. use the "ALL" option:
  184.  
  185.                    ICONtrol SYS:MyFiles/ freepos all
  186.  
  187.  
  188. Changing all icons on a volume
  189. ------------------------------
  190.     To recolor all icons on a disk in df0:, use:
  191.  
  192.                        ICONtrol df0: recolor all
  193.  
  194.     If  your  current directory is already set to "df0:", you can omit a
  195. path completely.  In this case,
  196.  
  197.                           ICONtrol recolor all
  198.  
  199. will do the job.
  200.  
  201.  
  202. Changing icons of a certain type
  203. --------------------------------
  204.     To recolor all icons on df0:  belonging to files (that is, tool- and
  205. project-icons), add the type:
  206.  
  207.                     ICONtrol df0: recolor all files
  208.  
  209.     Say  you wanted to make all the drawer icons on your harddisk "dh0:"
  210. look like the drawers on newer Fish disks:
  211.  
  212.            ICONtrol dh0: getimage AmigaLibDisk500:Signal all
  213.  
  214. This  uses  "Signal.info" on Fish 500 as source for all icons on "dh0:".
  215. Since  ICONtrol  knows  its  a  drawer  icon, it will set this image for
  216. drawers only.
  217.  
  218.  
  219.                                Known Bugs
  220.                                ==========
  221.  
  222.     There  IS  a  problem  when  using  ICONtrol  on "RAM:":  Do not use
  223. wildcards  when  operating on the RAM-disk; the program will process the
  224. same   files   over   and   over   again,  get  hung  or  produce  other
  225. nondeterministic garbage.
  226.     This  is  not  ICONtrol's  fault,  but  seems to be a problem of the
  227. ram-handler:   It  probably  looses control of an ExNext()-chain when it
  228. writes  to  its  volume  during  a scan.  That is the case when ICONtrol
  229. writes  back  a  modified  icon  and wants to continue with scanning the
  230. directory  after  that.   I suppose the  handler  does  not  update  the
  231. information  it  uses for ExNext() to reflect the changes that have been
  232. made  by  the  write  operation.   Thus  it gets confused when trying to
  233. execute the next ExNext() using out-of-date InfoBlocks.
  234.     Since  this is a system problem, I see no reason why ICONtrol should
  235. try  to  get  round the problem.  If you do not trust ICONtrol to access
  236. your  harddisk  or  disk directly, you still can use "RAD:" to copy your
  237. icons to, change them there and then copy them back.
  238.     What  really  surprised  me is, provided my assumptions are correct,
  239. that ram-handler has not been fixed over all these years.  The bug still
  240. exists under OS 2.0.  Has anybody encountered the same problem before?
  241.  
  242.  
  243.                          COPYRIGHT & DISCLAIMER
  244.                          ======================
  245.  
  246.     ICONtrol  is  copyright  ©  1991  by  Stefan Winterstein, all rights
  247. reserved.   This program is not public domain, but freely distributable,
  248. provided  it is not modified in its operation, distributed together with
  249. this documentation and used for non-commercial purposes only.
  250.     Though  it  was tested rather thoroughly, ICONtrol is made available
  251. "as-is",  without warranty of any kind.  Any damage caused by the use of
  252. this program is the sole responsibility of the user.
  253.  
  254.  
  255.                             Revision History
  256.                             ================
  257.  
  258. 1.0 (21-Oct-91)
  259. ---------------
  260.     First release, sent to Fred Fish.
  261.  
  262.  
  263.                              Contributions
  264.                              =============
  265.  
  266.     ICONtrol was developed under Kickstart 1.3 using SAS_C 5.10.  It has
  267. also  been  tested on systems with OS 2.0 (Version 37.143) and Kickstart
  268. 1.2.
  269.     The pattern matching routine used is PatMatch, found with the source
  270. of  "dr"  on  Fish disk 429; it was ported from BCPL by Jeff Lydiatt and
  271. enhanced  by Paul Kienitz.  The CLI parser was inspired by Dave Haynie's
  272. "SetCPU" from Fish disk 400.
  273.     Many  thanks  go to my fellow students Tom Kroener, Oliver Kripfgans
  274. and Lothar Fritsch for useful suggestions and beta testing.
  275.     If  you  have  any  comments, complaints or suggestions on ICONtrol,
  276. feel free to contact me (sorry, E-Mail not available, yet):
  277.  
  278.                            Stefan Winterstein
  279.                             Schwarzbachstr.7
  280.                             W-6650 Homburg 6
  281.                                 GERMANY
  282.  
  283.     I  would  like  to  thank  all  programmers who have made their work
  284. available  through  Public Domain and Freeware, and namely Fred Fish for
  285. his outstanding work for the programmers' community.
  286.  
  287.         They all "make the Amiga shine the way it was meant to".
  288.